package com.thyc.enums;

public enum  EquipmentEnum {

    ONE("C01","260011","1-X"),
    TWO("C02","260007","1-Y"),
    THREE("C03","260006","1-Z"),
    FOUR("C04","260015","2-Y"),
    FIVE("C05","208557","2-Z"),
    SIX("C06","260008","3-X"),
    SEVEN("C07","260013","3-Y"),
    EIGHT("C08","260005","3-Z"),
    NINE("C09","260016","4-Y"),
    TEN("C10","208547","4-Z"),
    ELEVEN("C11","260012","5-X"),
    TWELVE("C12","260014","5-Y"),
    THIRTEEN("C13","260004","5-Z"),
    FOURTEEN("C14","260010","6-X"),
    FIFTEEN("C15","260009","6-Y"),
    SIXTEEN("C16","208551","6-Z");

    private String channelNum;
    private String sensorNumber;
    private String sensorModel;

    public String getChannelNum() {
        return channelNum;
    }

    public String getSensorNumber() {
        return sensorNumber;
    }

    public String getSensorModel() {
        return sensorModel;
    }

    public static EquipmentEnum getByChannel(String channelNum) {
        EquipmentEnum[] values = EquipmentEnum.values();
        for (EquipmentEnum value : values) {
            if (value.channelNum.equals(channelNum)) {
                return value;
            }
        }
        return null;
    }

    EquipmentEnum(String channelNum, String sensorNumber, String sensorModel) {
        this.channelNum = channelNum;
        this.sensorNumber = sensorNumber;
        this.sensorModel = sensorModel;
    }
}
